scaffold: local metadata methods + response capture (host-local recall)#67
Merged
Alexgodoroja merged 1 commit intoJul 4, 2026
Merged
Conversation
84743dc to
bdd3684
Compare
An HTTP app can now persist a method's result to a host-local JSON file and read
it back with a backend-free local method — so an agent recalls host-local state
without a round-trip (e.g. agentphone: buy_number writes the provisioned number
to ~/.pilot/.agentphone; mynumber reads it).
- Method.local {store} — a local read (no http/cli route); returns the store's
JSON, or {"entries":[]} when absent. Plane "local" in <ns>.help.
- HTTPRoute.capture_to — after a 2xx, best-effort append the response to the
store's "entries" array (deduped by id). A capture failure never fails the call.
- Manifest auto-grants fs.read (+ fs.write for capture targets) on the store,
with ~ normalized to $HOME (adapter expands ~ at runtime, so grant == path).
- Submission (rich) carries local.store + http.capture_to through ToConfig;
validation rejects a method with both a local and a backend route.
Tests: generate+compile a managed-http app with capture + local read, asserting
the dispatcher wiring, the $HOME grants, and validation rules. Full suite green.
Alexgodoroja
pushed a commit
to Alexgodoroja/app-template
that referenced
this pull request
Jul 4, 2026
…cal number recall Managed AgentPhone app: keyless adapter → Pilot broker (holds the master key, meters each user against a $5 budget → 402) → https://api.agentphone.ai. - 53 methods covering every non-streaming /v1 endpoint (agents, numbers, messages, calls, conversations, contacts, contact-cards, usage, voices, webhooks). Every method described; params tagged path/query/body. No websockets — poll for status. - Local number recall: buy_number captures the provisioned number to ~/.pilot/.agentphone; agentphone.mynumber reads it back locally (no round-trip). - verify-submission builds + verifies darwin/linux amd64+arm64. Requires the broker credit gate (pilot-protocol#64) + method-aware costs (pilot-protocol#66) + local-metadata scaffold (pilot-protocol#67), all merged.
Alexgodoroja
added a commit
that referenced
this pull request
Jul 4, 2026
…cal number recall (#65) Managed AgentPhone app: keyless adapter → Pilot broker (holds the master key, meters each user against a $5 budget → 402) → https://api.agentphone.ai. - 53 methods covering every non-streaming /v1 endpoint (agents, numbers, messages, calls, conversations, contacts, contact-cards, usage, voices, webhooks). Every method described; params tagged path/query/body. No websockets — poll for status. - Local number recall: buy_number captures the provisioned number to ~/.pilot/.agentphone; agentphone.mynumber reads it back locally (no round-trip). - verify-submission builds + verifies darwin/linux amd64+arm64. Requires the broker credit gate (#64) + method-aware costs (#66) + local-metadata scaffold (#67), all merged. Co-authored-by: Alex Godoroja <alex@vulturelabs.io>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Lets an HTTP app persist a method's result to a host-local JSON file and read it back with a backend-free local method — so an agent recalls host-local state without a round-trip. Built for AgentPhone:
buy_numberwrites the provisioned number to~/.pilot/.agentphone, andagentphone.mynumberreads it.method.local: {store}— a local read (no http/cli route); returns the store's JSON (or{"entries":[]}when absent). Shows as planelocalin<ns>.help.http.capture_to— after a 2xx, best-effort append the response to the store's"entries"array (deduped byid); a capture failure never fails the call.fs.read(+fs.writefor capture targets) on the store,~→$HOMEnormalized (the adapter expands~at runtime, so grant == opened path).local.store+http.capture_tothroughToConfig; validation rejects a method declaring both a local and a backend route.Tests: generate+compile a managed-HTTP app with capture + local read, asserting dispatcher wiring, the
$HOMEgrants, and validation. Full suite green.